<!DOCTYPE html>
<html lang="zh-CN" th:fragment="layout (title, style, script, heading, content, selcur)" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">

    <title th:replace="${title}">页面标题</title>

    <link th:href="@{{su}/common/css/bootstrap.min.css(su=${staticUrl})}" rel="stylesheet">
    <link th:href="@{{su}/common/font-awesome/css/font-awesome.css(su=${staticUrl})}" rel="stylesheet">

    <link th:href="@{{su}/common/css/animate.css(su=${staticUrl})}" rel="stylesheet">
    <link th:href="@{{su}/common/css/style.css(su=${staticUrl})}" rel="stylesheet">

    <!-- Sweet Alert -->
    <link th:href="@{{su}/common/css/plugins/sweetalert/sweetalert.css(su=${staticUrl})}" rel="stylesheet">

    <th:block th:replace="${style}"/>
</head>
<body class="md-skin fixed-sidebar fixed-nav fixed-nav-basic">
<div id="wrapper">
    <nav class="navbar-default navbar-static-side" role="navigation">
        <div class="sidebar-collapse">
            <ul class="nav metismenu" id="side-menu">
                <li class="nav-header">
                    <div class="dropdown profile-element">
                        <a data-toggle="dropdown" class="dropdown-toggle" href="#">
                            <span class="block m-t-xs font-bold" th:text="${loginUser}?${loginUser.loginName}:_">郭超</span>
                            <span class="text-muted text-xs block">菜单 <b class="caret"></b></span>
                        </a>
                        <ul class="dropdown-menu animated fadeInRight m-t-xs">
                            <li><a class="dropdown-item" th:href="@{{su}/user/exit(su=${staticUrl})}">注销</a></li>
                        </ul>
                    </div>
                    <div class="logo-element">
                        IN+
                    </div>
                </li>
                <li th:class="${#strings.startsWith(selcur,'project-')}?'active'">
                    <a href="#"><i class="fa fa-edit"></i> <span class="nav-label">项目管理</span><span class="fa arrow"></span></a>
                    <ul class="nav nav-second-level">
                        <li th:class="${selcur}=='project-list'?'active'"><a th:href="@{{su}/project/list(su=${staticUrl})}">项目列表</a></li>
                        <li th:class="${selcur}=='project-save'?'active'"><a th:href="@{{su}/project/add(su=${staticUrl})}">项目添加</a></li>
                    </ul>
                </li>
            </ul>
        </div>
    </nav>

    <div id="page-wrapper" class="gray-bg">
        <div class="row border-bottom">
            <nav class="navbar navbar-fixed-top white-bg" role="navigation" style="margin-bottom: 0">
                <div class="navbar-header">
                    <a class="navbar-minimalize minimalize-styl-2 btn btn-primary " href="#"><i class="fa fa-bars"></i>
                    </a>
                </div>
                <ul class="nav navbar-top-links navbar-right">
                    <li>
                        <a th:href="@{{su}/user/exit(su=${staticUrl})}">
                            <i class="fa fa-sign-out"></i> 注销
                        </a>
                    </li>
                </ul>
            </nav>
        </div>
        <div th:replace="${heading}"></div>
        <div th:replace="${content}"></div>
        <div class="footer">
            <div class="pull-right">
                10GB of <strong>250GB</strong> Free.
            </div>
            <div>
                <strong>Copyright</strong> Example Company &copy; 2014-2018
            </div>
        </div>
    </div>
</div>

<!-- Mainly scripts -->
<script th:src="@{{su}/common/js/jquery-3.1.1.min.js(su=${staticUrl})}"></script>
<script th:src="@{{su}/common/js/popper.min.js(su=${staticUrl})}"></script>
<script th:src="@{{su}/common/js/bootstrap.min.js(su=${staticUrl})}"></script>
<script th:src="@{{su}/common/js/plugins/metisMenu/jquery.metisMenu.js(su=${staticUrl})}"></script>
<script th:src="@{{su}/common/js/plugins/slimscroll/jquery.slimscroll.min.js(su=${staticUrl})}"></script>
<script th:src="@{{su}/qmy/js/common.js(su=${staticUrl})}"></script>

<!-- Custom and plugin javascript -->
<script th:src="@{{su}/common/js/inspinia.js(su=${staticUrl})}"></script>
<script th:src="@{{su}/common/js/plugins/pace/pace.min.js(su=${staticUrl})}"></script>
<!-- Sweet alert -->
<script th:src="@{{su}/common/js/plugins/sweetalert/sweetalert.min.js(su=${staticUrl})}"></script>
<th:block th:replace="${script}"/>
</body>
</html>
